﻿using Microsoft.AspNetCore.Http;
using Microsoft.AspNetCore.Mvc;
using Simple.ISysService;
using Simple.Tools;
using SimpleSaas.Common;
using SimpleSaas.Web.Common;
using SqlSugar;

namespace SimpleSaasUser.Controllers
{
	[Route("api/system-initialize")]
	[ApiController]
	public class SystemInitializeController : BaseController
	{
		[Autowired]
		protected ISystemInitializeService systemInitializeService { get; set; }

		public SystemInitializeController()
		{

		}
		/// <summary>
		/// 系统初始化完成最好将该接口弃用
		/// </summary>
		/// <returns></returns>
		[HttpPost("create/database-tables")]
		public async Task<SimpleSaas.Common.BaseMessage> DatabaseTablesAsync()
		{
			await systemInitializeService.DatabaseCreateTablesAsync();
			return Ok200();
		}
	}
}
